package beans;

import java.io.Serializable;

public class CajaBean implements Serializable{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private Integer id;
	private float efectivo;
	private float tarjetaCredito;
	private float tarjetaDebito;
	private float cupones;
	
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	public float getEfectivo() {
		return efectivo;
	}
	public void setEfectivo(float efectivo) {
		this.efectivo = efectivo;
	}
	public float getTarjetaCredito() {
		return tarjetaCredito;
	}
	public void setTarjetaCredito(float tarjetaCredito) {
		this.tarjetaCredito = tarjetaCredito;
	}
	public float getTarjetaDebito() {
		return tarjetaDebito;
	}
	public void setTarjetaDebito(float tarjetaDebito) {
		this.tarjetaDebito = tarjetaDebito;
	}
	public float getCupones() {
		return cupones;
	}
	public void setCupones(float cupones) {
		this.cupones = cupones;
	}
	
	public CajaBean() {
	
	}
	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + Float.floatToIntBits(cupones);
		result = prime * result + Float.floatToIntBits(efectivo);
		result = prime * result + ((id == null) ? 0 : id.hashCode());
		result = prime * result + Float.floatToIntBits(tarjetaCredito);
		result = prime * result + Float.floatToIntBits(tarjetaDebito);
		return result;
	}
	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		CajaBean other = (CajaBean) obj;
		if (Float.floatToIntBits(cupones) != Float
				.floatToIntBits(other.cupones))
			return false;
		if (Float.floatToIntBits(efectivo) != Float
				.floatToIntBits(other.efectivo))
			return false;
		if (id == null) {
			if (other.id != null)
				return false;
		} else if (!id.equals(other.id))
			return false;
		if (Float.floatToIntBits(tarjetaCredito) != Float
				.floatToIntBits(other.tarjetaCredito))
			return false;
		if (Float.floatToIntBits(tarjetaDebito) != Float
				.floatToIntBits(other.tarjetaDebito))
			return false;
		return true;
	}
	
	
	
	
}
